import unittest
import time
import HTMLTestRunner
import sys
import io

from com.wzh.mile.unit_test.common.webdriver_single import WebDriverSingle
from com.wzh.mile.unit_test.toumile.mile_suite import suite_login_from_main, suite_login_and_charge, \
    suite_login_and_auth_name, suite_login_and_auth_name_and_set_payment_password, suite_bind_bank_card, \
    suite_login_and_charge2, suite_all, suite_invest_for_many_times
import os

# print(os.getcwd())#获得当前工作目录
# print( os.path.abspath('.'))#获得当前工作目录
# print (os.path.abspath('..'))#获得当前工作目录的父目录
# print (os.path.abspath(os.curdir))#获得当前工作目录
# unit_test.TextTestRunner().run(suite_login_from_main())
# unit_test.TextTestRunner().run(suite_login_and_charg())
#
#
#e())
# unit_test.TextTestRunner().run(suite_login_and_auth_name())
from com.wzh.mile.unit_test.toumile_oss.OssLogin import OssTestLogin


# 登录
def suite_login_from_main():
    suit_login = unittest.TestSuite()
    suit_login.addTest(OssTestLogin('test_oss_login'))
    return suit_login





if __name__ == '__main__':
    filename = 'D:\Report.html'
    with open(filename, 'wb') as fp:
        html_runner = HTMLTestRunner.HTMLTestRunner(stream=fp, title='投米乐自动化测试报告', description='主干流程业务覆盖')
        html_runner.run(suite_login_from_main())
